import Vue from 'vue'
import Router from 'vue-router'
import routerConfig from './routerConfig'
Vue.use(Router)

const vueRouter = new Router({
  routes: routerConfig
})

// 全局路由守卫
vueRouter.beforeEach((to, from, next) => {
  document.title = `袁婷婷-${to.meta.title}`
  next()
})
export default vueRouter
